<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
  var a=3;
  function c(){
    alert(a); // 3
  }
  (function(){
    var a=4;
    c();
  })();
</script>
</body>
</html>
